
import java.util.Scanner;

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author Fariz
 */
public class Segitiga {
    public static void main(String[] args) {
         Scanner input=new Scanner(System.in);
        int a, k;
                  
        System.out.print("Masukkan bilangan bulat : ");
        a = input.nextInt();
        System.out.print("Faktornya adalah : ");
        for (k=1;k<=a;k++){
            if (a % k == 0){
                if (a==k){
                    System.out.println("dan "+k);
                }
                else
                System.out.print(k + ", ");
            }
        }
    }
}
